import Vue from 'vue'
import VueResource from 'vue-resource';
Vue.use(VueResource);

export default {
  /**
   * 中止流程
   */
  abortProcess(actId,refuseReason) {
    return Vue.http.post("/memberActivity/m/abortProcess/"+actId,refuseReason);
  },
  /**
   * 获取流程所需要的步骤
   */
  getMemberStepResult(actId) {
    return Vue.http.get("/memberActivity/m/activity/"+actId+"/logs");
  },

  /**
   * 获取流程当前任务
   */
  getCurrentSteps(actId) {
    return Vue.http.get("/memberActivity/m/activity/"+actId+"/currentsteps");
  },
  /**
   * 获取所有会员信息
   */
  getAllMemberInfor() {
    return Vue.http.post("/member/m/v1/getAllMember");
  },
  /**
   * 获取所有入住的会员信息
   */
  getAllCheckInMemberInfor(){
    return Vue.http.post("/member/m/v1/getAllCheckInMember");
  },
  /**
   * 获取任务的审核进度
   */
  getTaskStep(taskId){
    return Vue.http.post("/memberActivity/m/queryTaskStep/"+taskId);
  },
  /**
   * 获取所有员工
   */
  getAllEmp(){
    return Vue.http.get("/memberActivity/m/orgEmps");
  },
  /**
   * 查询入住评估量表结果(照护等级)
   */
  getCareGrade(){
    return Vue.http.get("/serviceCombo/getCareLevelList");
  },
  /**
   * 获取服务计划套餐列表
   */
  getServiceList(val){
    return Vue.http.post("/servicePlan/getMemberUseServiceList",val);
  },
  /**
   * 审核--退住申请表
   */
  getRetirementApplicationForm(actId){
    return Vue.http.get("/memberActivity/m/getMemberOutApply/"+actId);
  },
  /**
   * 审核--换床申请表
   */
  getChangeBedApplicationForm(actId){
    return Vue.http.get("/memberActivity/m/getMemberBedChange/"+actId);
  },
  /**
   * 套餐变更申请表
   */
  getMemberComboChange(actId){
    return Vue.http.get("/memberActivity/m/getMemberComboChange/"+actId);
  },
  /**
   * 根据业务信息支付信息查询
   */
  getAccountBillByAct(memberId,actId,viewBed){
    return Vue.http.get("/account/m/v1/getBillConfirmByAct/"+memberId+'/'+actId+'/'+viewBed);
  },
  /**
   * 查询审批结果(会员模块--定哥的接口)
   */
  getApprovalResult(actId){
    return Vue.http.get("/memberActivity/m/approvals/activities/"+actId+"/results");
  },
  /**
   * 中止流程
   */
  getResolvedSteps(actId) {
    return Vue.http.get("/memberActivity/m/activities/"+actId+"/solvedsteps");
  },
  /**
   * 流程确认接口(入住确认，退住确认，套餐变更确认，换床确认)
   */
  confirmCompleteProcess(actId){
    return Vue.http.post("/memberActivity/m/confirmCompleteProcess/"+actId);
  },
  /**
   * 备注
   */
  getRemark(actId,data){
    return Vue.http.post("/memberActivity/m/addComment/"+actId,data);
  },
  /**
   * 跳转到下一页
   */
  getFlowRouter(processKey,actId,data){
    return Vue.http.post("/memberActivity/m/flowRouter/"+processKey+"/"+actId,data);
  }
}
